<template>
    <div class="dialogSort">
        
        <van-action-sheet v-model="show" :actions="datum.actions" @select="onSelect" />
    </div>
</template>

<script>
    import { Toast } from 'vant';
import { defineComponent,reactive,ref } from 'vue'
export default defineComponent({
  setup(props,context) {
      let show = ref(true);
      const datum = reactive({
        actions: [{ name: '选项一' }, { name: '选项二' }, { name: '选项三' }],
      })

      const shows = () =>{
            show.value = true; 
        }

      const onSelect = (item) => {
        Toast(item.name);
        show.value = false;
      }

      
      return {    
        show,
        datum,
        onSelect,
        shows
      }
  },
})
</script>

<style lang='less'>
.dialogSort{
    width: 100%;
    height: 100%;
    position: absolute;
    left: 0;
    top: 0;
    z-index: 99;
    .sort_cont{
        position: absolute;
        bottom: 0;
        width: 100%;
        height: 200px;
        background: #fff;
    }
}
</style>
